You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
After investigation of the issue with share_plus crashing apps on iPhones when no sharePositionOrigin provided and app is build with Xcode 26 I made an interesting discovery - when project is built with Xcode 26 hasPopoverPresentationController returns true both for iPhones and for iPads, while in the same project, but built with Xcode 16.4 and older value is true only for iPads.
Here is example app built with Xcode 16.4 running on iPhone:
Here is example app built with Xcode 26.0.1 running on iPhone:
Due to this difference plugin was throwing exception when no sharePositionOrigin was provided causing multiple bug reports here.
I have added an additional check for iPad which should solve the problem. With this change sharePositionOrigin is not required on iPhones as it was before.
Fellow devs remember:
If you're updating to the version 12.0.1 that has this fix but it seems "it's not working for you", do first flutter clean and then do flutter pub get so you truly get this last version.
(It happened to me, so leaving it here as a help!)
This error recently reappeared in my app's logs, with the notable exception that the device in question is an iPad. Could it be that this error is occurring only on that device? I haven't had any issues on the iPhone since I updated the package to version 12.0.1.
iPad (9th generation) with iPadOS 26.4.1
share_plus v12.0.1
Non-fatal Exception: FlutterError
PlatformException(error, sharePositionOrigin: argument must be set, {{0, 0}, {0, 0}} must be non-zero and within coordinate space of source view: {{0, 0}, {1080, 810}}, null, null).
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
share_plusFeature, Enhancement, Bug Fixes for Share Plus Plugin
3 participants
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
After investigation of the issue with
share_pluscrashing apps on iPhones when nosharePositionOriginprovided and app is build with Xcode 26 I made an interesting discovery - when project is built with Xcode 26 hasPopoverPresentationController returnstrueboth for iPhones and for iPads, while in the same project, but built with Xcode 16.4 and older value istrueonly for iPads.Here is example app built with Xcode 16.4 running on iPhone:

Here is example app built with Xcode 26.0.1 running on iPhone:

Due to this difference plugin was throwing exception when no
sharePositionOriginwas provided causing multiple bug reports here.I have added an additional check for iPad which should solve the problem. With this change
sharePositionOriginis not required on iPhones as it was before.Related Issues
Closes #3645
Breaking Change
Does your PR require plugin users to manually update their apps to accommodate your change?
!in the title as explained in Conventional Commits).